Skip to content

CLI for Configuring PFC Historical Statistics#3779

Merged
vmittal-msft merged 3 commits intosonic-net:masterfrom
peterbailey-arista:pfc-stat-hist-config
Aug 5, 2025
Merged

CLI for Configuring PFC Historical Statistics#3779
vmittal-msft merged 3 commits intosonic-net:masterfrom
peterbailey-arista:pfc-stat-hist-config

Conversation

@peterbailey-arista
Copy link
Copy Markdown
Contributor

@peterbailey-arista peterbailey-arista commented Feb 25, 2025

What I did

Added support for configuring pfc statistical history through following commands:

  • config pfcwd start --pfc-stat-history
  • config pfcwd pfc_stat_history <enable|disable>
  • show pfcwd config

These changes were made for the PFC Historical Statistics feature: sonic-net/SONiC#1904

How I did it

  • Added to the PFCWD script with a pfc-stat-history flag for starting the watchdog with history enabled
  • Added to the PFCWD script with a pfc_stat_history command for enabling/disabling history on selected ports

How to verify it

  • Run the sonic-utilities unit tests
  • Run config pfcwd start <ports> <detection-time> --pfc-stat-history on a switch, verify the configurations with show pfcwd config
  • Run config pfcwd pfc_stat_history enable|disable <ports> on a switch, verify the configurations with show pfcwd config

New command output (if the output of a command-line utility has changed)

Example output of show pfcwd config:

Changed polling interval to 600ms
     PORT    ACTION    DETECTION TIME    RESTORATION TIME    HISTORY
---------  --------  ----------------  ------------------  ---------
Ethernet0   forward               102                 101    disable
Ethernet4      drop               600                 600     enable
Ethernet8      drop               600                 600    disable

Loading
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants